#include "Achievement.h"
#include <iostream>

using namespace std;
static int JumpCount = 0;
static bool AchJump = false;
static bool AchJump50 = false;

void AchSetJump(int value)
{
	JumpCount = value;
	if(JumpCount >= 5 && !AchJump)
	{
		cout << "Good Job Jumping 5 times" << endl;
		AchJump = true;
	}
	if(JumpCount >= 50 && !AchJump50)
	{
		cout << "Good Job Jumping 50 times" << endl;
		AchJump50 = true;
	}
}

void AchAddJump(int value)
{
	JumpCount += value;
	if(JumpCount >= 5 && !AchJump)
	{
		cout << "Good Job Jumping 5 times" << endl;
		AchJump = true;
	}
	if(JumpCount >= 50 && !AchJump50)
	{
		cout << "Good Job Jumping 50 times" << endl;
		AchJump50 = true;
	}
}

int AchGetJumpCount(void)
{
	return JumpCount;
}

bool AchGetJump (void)
{
	return AchJump;
}

bool AchGetJump50 (void)
{
	return AchJump50;
}

static int EnemiesKilledCount = 0;
static bool AchEnemiesKilled = false;
static bool AchEnemiesKilled20 = false;

void AchSetEnemiesKilled(int value)
{
	EnemiesKilledCount = value;
	if(EnemiesKilledCount >= 5 && !AchEnemiesKilled)
	{
		cout << "Good Job Killing 5 Enemies" << endl;
		AchEnemiesKilled = true;
	}
	if(EnemiesKilledCount >= 20 && !AchEnemiesKilled20)
	{
		cout << "Good Job Killing 20 Enemies" << endl;
		AchEnemiesKilled20 = true;
	}
}

void AchAddEnemiesKilled(int value)
{
	EnemiesKilledCount += value;
	if(EnemiesKilledCount >= 5 && !AchEnemiesKilled)
	{
		cout << "Good Job Killing 5 Enemies" << endl;
		AchEnemiesKilled = true;
	}
	if(EnemiesKilledCount >= 20 && !AchEnemiesKilled20)
	{
		cout << "Good Job Killing 20 Enemies" << endl;
		AchEnemiesKilled20 = true;
	}
}

int AchGetEnemiesKilledCount(void)
{
	return EnemiesKilledCount;
}

bool AchGetEnemiesKilled(void)
{
	return AchEnemiesKilled;
}

bool AchGetEnemiesKilled20(void)
{
	return AchEnemiesKilled20;
}

static int ItemGetCount = 0;
static bool ItemGet10 = false;
static bool ItemGet20 = false;

void AchSetItemGetCount (int value)
{
	ItemGetCount = value;
	if(ItemGetCount >= 10 && !ItemGet10)
	{
		cout << "Good Job Collecting 10 Items" << endl;
		ItemGet10 = true;
	}
	if(ItemGetCount >= 20 && !ItemGet20)
	{
		cout << "Good Job Collecting 20 Items" << endl;
		ItemGet20 = true;
	}
}

void AchAddItemGetCount (int value)
{
	ItemGetCount += value;
	if(ItemGetCount >= 10 && !ItemGet10)
	{
		cout << "Good Job Collecting 10 Items" << endl;
		ItemGet10 = true;
	}
	if(ItemGetCount >= 20 && !ItemGet20)
	{
		cout << "Good Job Collecting 20 Items" << endl;
		ItemGet20 = true;
	}
}

int AchGetItemGetCount (void)
{
	return ItemGetCount;
}

bool AchGetItemGet10 (void)
{
	return ItemGet10;
}

bool AchGetItemGet20 (void)
{
	return ItemGet20;
}